home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Magnum One
/
Magnum One (Mid-American Digital) (Disc Manufacturing).iso
/
d20
/
ubm_102.arc
/
EXAMPLES.DOC
< prev
next >
Wrap
Text File
|
1990-12-30
|
12KB
|
481 lines
UM - Userlevel Maintainer definitionsfile. Version 1.01
Copyright (c) Joep Vullinghs, 1990. All Rights Reserved.
This file contains 14 examples of definitions. Five of them are
already listed in the UM.CFG-example. Note that, except for the
last example, no keywords like ~USERSNAME~ are used. You are
of course allowed to add them yourself.
If you have got ideas to make a more complete summary of the
possibilities of UM, please drop me a note at 2:283/201.
1. New users
2. Expiring memberships
3. Warning paying members about their level
4. Warn naughty users
5. Messages to all users
6. Asking ANSI-users to use the full-screen editor
7. Downloader who don't pay, nor load something up
8. Sending message non-paying members that have called 15+ times
9. Warning to users who don't call frequently
10. Purging users who haven't called in six months
11. Giving users membership-level
12. Asking users to change their passwords
13. Up/download ratios
14. TRASHCAN
1. New users
This definition sends new users a message and also increases their level.
In this example, level 5 is the level new users get, and level 10 is the
level of "normal" users, i.e. users who have called more times and don't have
a special level.
BEGIN
FROM New user
TO Normal user
BEFORE
LEVEL 5
AFTER
LEVEL 10
MESSAGE
Welcome!
You have been registered as a new user. Therefore, your level has been
updated. The only strict rule on this BBS is that you are not allowed
to shout at the sysop. Other rules will be made by me when I need them.
See ya around at this BBS!
Your sysop.
$END
SUBJECT Welcome!
END
2. Expiring memberships
This example uses a counter in the HomePhone-field to determine if someone's
Paying-membership has expired. Therefore, a USE HOMEPHONE must be used in UBM.CFG to
make sure that UBM decrements the counters.
To make someone a Paying-Member, give him the appropiate level and enter the
number of days in the HomePhone-field (for example 365). In this example,
paying members have level 500 and flag A1 set.
BEGIN
FROM Paying member
TO Normal user
BEFORE
LEVEL 500
FLAG A X-------
HOMEPHONE 0
AFTER
LEVEL 10
FLAG A 0-------
MESSAGE
Dear member,
as the paying-membership-period has expired, your level has been decreased to
10. Prolonging your membership costs only $10 a year.
I hope to see your check soon.
Your sysop.
$END
SUBJECT Membership expired
END
3. Warning paying members about their level
If you want to have a message being send to users who are paying member,
but who's membership is about to expire, use this definition.
BEGIN
FROM Paying member
TO Warned paying member
BEFORE
LEVEL 500
FLAG A X-------
HOMEPHONE 14
AFTER
MESSAGE
Dear member,
Your membership will expire in two weeks. Make sure to pay $10 within a few
days or your level will be put back.
I hope to see your check soon.
Your sysop.
$END
SUBJECT Membership about to expire
END
4. Warn naughty users
If your users simply hang up if they want to leave your BBS instead of using
the appropriate menu you could use this definition. It writes messages to
those users. Some extra things need be done. You must reserve a flag to
keep track of the users who disconnect badly. In this example I used the
D1-flag. Two questionnaires must be made. The first is LOGON.Q-A which
contains:
SETFLAG D1 ON
QUIT
This questionnaire must be xecuted in your BBS immediately after a users has
logged on. You could use an automatical menu-option in TOP.MNU for example.
The second questionnaire is LOGOFF.Q-A which contains:
SETFLAG D1 OFF
QUIT
LOGOFF.Q-A must be executed automatically at every "legal" exit of your
BBS (for example in BYE.MNU).
Now D1 will be set if someone simply hung up instead of logging of.
This will be used to write a message. Note that the user's level is not
actually changed, only the D1-flag will be reset.
BEGIN
FROM Foolish normal user
TO Warned foolish user
BEFORE
FLAG D 1-------
AFTER
FLAG D 0-------
MESSAGE
Dear member,
Don't you ever, ever just disconnect again when you are connected to this BBS!
The only legal way to leave this BBS is by using the [!]-key in the mainmenu.
Your sysop.
$END
SUBJECT Logging off
END
Note that it is possible to use another flag to determine if a user logged off
incorrectly before. You could use that flag to delete a user from your BBS.
5. Messages to all users
This definition writes messages to all users at your BBS. It uses the C2-flag
to determine whether a user already received a message or not.
Note that by using combinations of flags you could write hundreds of letters.
BEGIN
FROM User without C2-letter
TO User with C2-letter
BEFORE
FLAG C -0------
AFTER
FLAG C -1------
MESSAGE
Hi,
This BBS needs sponsors! You could use this method of Direct-Mailing too.
Costs only $1 for 50 messages!
Your sysop.
$END
SUBJECT Sponsors needed
END
6. Asking ANSI-users to use the full-screen editor
A lot of users don't really understand what a full-screen editor is nor how
it works. This definition looks if a user is capable of using ANSI by checking
his ANSI-flag. If MBU finds a user who has got his ANSI-flag set, but his
full screen editor-flag is not set, a message is send and C3 is set to make
sure only one letter will be sent.
BEGIN
FROM User without full screen editor
TO Same user with letter
BEFORE
FLAG C --0-----
ANSI EDITOR OFF
ANSI ON
AFTER
FLAG C --1-----
MESSAGE
Hi,
You don't have your full screen editor-flag set! A full screen-editor is a
very easy and fast program that makes writing messages a lot easier. For more
info, see the bulletin "How to use the full screen-editor".
Your sysop.
$END
SUBJECT Full screen-editor.
END
7. Downloader who don't pay, nor load something up.
This example sends a message to every user who doesn't upload much (less than
50 K), aren't paying members (level is 10) and have downloaded more than 500 K.
C4 is used to determine if a user already received a letter. To make sure a
user who logs on one time, downloads a lot and sends money immediately doesn't
get bothered, the user must have called more than 6 times.
BEGIN
FROM Annoying user
TO Warned annoying user
BEFORE
FLAG C ---0----
DOWNLOAD K > 500
UPLOAD K < 50
LEVEL 10
TIMES > 6
AFTER
FLAG C ---1----
MESSAGE
Hi,
as you have downloaded a lot, but don't seem to pay, nor upload I ask you to
send some money for the time you are occupying my system.
Your sysop.
$END
SUBJECT Upload or pay!
END
8. Sending message non-paying members that have called 15+ times
This definition sends a warning to users who aren't paying members yet but
have called more than 15 times. C5 is used to determine whether a users didn't
get this already.
BEGIN
FROM Calling but not paying user
TO Same user, but warned
BEFORE
FLAG C ----0---
TIMES > 15
LEVEL 10
AFTER
FLAG C ----1---
MESSAGE
Hi,
This BBS was not meant to support users who call more than 15 times and don't
want to pay for their hobby.
Your sysop.
$END
SUBJECT Pay or stop calling!
END
9. Warning to users who don't call frequently.
If you're using a utility to purge users who haven't called for X days, you
can use this definition to send them a warning. Note that you can use this
example to send nice echomail to certain groups of users, too.
BEGIN
FROM Long time no see-user
TO Same user, but warned
BEFORE
DAYS AGO 90
AFTER
MESSAGE
Hi,
This BBS clears up it's userbase by deleting users who's last call was more
than half a year ago. So, if you don't want to risk being purged, call a bit
more often.
Your sysop.
$END
SUBJECT Calling
END
10. Purging users who haven't called in six months.
This definition actually deletes users who haven't called for six months.
BEGIN
FROM Long time no see-user
TO Same user, but deleted
BEFORE
DAYS AGO 180
AFTER
DELETE ON
$END
END
11. Giving users membership-level
If you want users to have membership-level, use this definition. It looks at
the D7-flag. If it's set, the user's A1-flag will be set, his level will
be raised to 500 and his counter in HomePhone will be set to 365 days. The
user's NO KILL flag will be set also. At last UBM writes a little message
to tell the user his money has arrived. Then it resets the D7-flag to make
sure the counter will not be raised every day.
BEGIN
FROM Normal user with D7 set
TO Member
BEFORE
FLAG D ------1-
AFTER
FLAG D ------0-
FLAG A 1-------
LEVEL 500
HOMEPHONE 365
NO KILL ON
SUBJECT Membership
MESSAGE
Hi user,
I've increased your level to that of a paying member. Thanks for supporting
this BBS! Your level will be decreased after a year. Two weeks before this
period ends you will get a warning letter.
Good luck with your new level!
Your sincerely,
Joep Vullinghs,
Sysop.
PS. If you don't call for a long time your record won't be deleted anymore.
$END
END
12. Asking users to change their passwords.
This definition asks your users to change their password after they have
called 5 times. D8 is used to check if a user already received this message.
BEGIN
FROM Fifth time caller
TO Fifth time caller with passw. warning.
BEFORE
FLAG D -------0
TIMES = 5
AFTER
FLAG D -------1
SUBJECT Password
MESSAGE
Dear Mr. ~username~,
You have called more than 5 times now. It's time to change your password
(now "~password~") to maintain full security.
Your sincerely,
Joep Vullinghs,
Sysop.
$END
END
13. Up/download ratios.
Although I don't like the idea of up/downloadratios myself, I decided to
include that option, too. In this example, 10 is the level of normal users,
i.e. the ONLY users whose level you want to be changed according to their
ratio. This means that levels of, for instance, paying members won't be
altered. If a user had downloaded too much his level will be decreased to
9. If he has level 9 and uploaded enough, his level will be increased again.
Users are allowed to download 200 k without uploading anything. That's why the
following statement need be specified in the global part of the configuration-
file:
FREE DOWNLOAD 500
If you wouldn't specify this, users wouldn't be able to download anything
without uploading first.
You want users to be able download 5 times as much as they upload (disregarding
the free download amount).
This is the definition that decreases the user's level:
BEGIN
FROM Normal user
TO No more download-user
BEFORE
LEVEL 10
RATIO WORSE 5
; This condition is met if the user has downloaded MORE than
; 100 + 5 * <UserUpload>
; (100 = FreeDownload, 5 = limit-ratio)
AFTER
LEVEL 9
MESSAGE
Hi ~username~,
You have downloaded too much! You have uploaded ~uploadk~. Therefore, you
are allowed to download 500 K + 4 * ~uploadk~ K = ~allowed~ K. As you have
downloaded ~downloadk~ K, you will have to upload first before you are allowed
to download again.
Your sysop.
$END
; end of message.
SUBJECT Upload needed!
END
And this is the definition that increases the level to 10 again.
BEGIN
FROM No more download-user
TO Normal user
BEFORE
LEVEL 9
RATIO BETTER 5
; This condition is met if the user has downloaded LESS than
; 500 + 5 * <UserUpload>
AFTER
LEVEL 10
MESSAGE
Hi ~username~,
Thanks for uploading! Now you are allowed to download again. You have
uploaded ~uploadk~ K so the total amount of download you are entitled to is
~allowed~ K. You have downloaded ~downloadk~ K so there is ~left~ K left.
Your sysop.
$END
; end of message.
SUBJECT Download allowed again
END
14. TRASHCAN
This definition deletes everyone whose name was specified in a list called
TRASHCAN.UBM. Although the user will be deleted, a message is being written.
NB 1. This message will only be read if the user logs on under the same name
again. NB 2. With a few minor changes you can use this definition to
increment someones level.
BEGIN
FROM Normal user
TO Deleted trash-user
BEFORE
LEVEL 10
MEMBER OF TRASHCAN.UBM
AFTER
DELETED ON
MESSAGE
Hi ~username~,
I can see you have logged again! You're not allowed to do so! Therefor, you
will be deleted again.
Your sysop.
$END
; end of message.
SUBJECT You're not supposed to read this!
END